<template>
	<div class="main">
		<div class="form-container">
			<div  class="form-main">
				<span class="one_title">&nbsp;&nbsp;三、返程情况&nbsp;&nbsp;</span>
                <!-- 新增 -->
                
                <label for="passHubei" class="littleTile" required>1. 是否外地返程</label><span class="required" style="color:red">*</span><br/>
                <div class="form-border form-twoBor" style='border: 1px solid #c6c8c9;'>
                    <div >
                        <el-radio v-model="giveBack" label="0">否</el-radio>
                    </div>
                    <div style="border-top: 1px solid #c6c8c9;" >
                        <el-radio v-model="giveBack" @change="isReturnOrNot" label="1">是</el-radio>
                    </div>
                </div>
				<div v-show="showBackdiv">
					<div class="residence">
										
										<label for="residence" class="littleTile">2. 去程起始地点</label><span class="required" style="color:red">*</span><br/>
										<input class="form-border" id="residence" type="text" readonly @click="openCityShow('residence')" name="residence"  placeholder="请填写去程起点" v-model="residence"  /> <br/>
									</div>
					
					<label for="vehicle" required class="littleTile">3. 去程交通工具</label><span class="required" style="color:red">*</span><br/>
					
					<div class="form-border tizheng clearfix" style='border: 1px solid #c6c8c9;'>
						<div>
							<el-checkbox  v-model="vehicle" label="火车"></el-checkbox>
						</div>
						<div>
							<el-checkbox  v-model="vehicle" label="飞机"></el-checkbox>
						</div>
						<div>
							<el-checkbox  v-model="vehicle" label="自驾"></el-checkbox>
						</div>
					</div>
					<div class="yy-c trainNumber">
						<label for="vehicle">4. 车次号/航班号/自驾车牌照</label>
						<input class="form-border" id="trainNumber" maxlength="32" type="text" name="trainNumber"   placeholder="请输入车次或航班号"  v-model="trainNumber"  /> <br/>
					</div>
					<!-- 返程 -->
					<div class="residence"> 
										
										<label for="residence">5. 返程起始地点</label><span class="required" style="color:red">*</span><br/>
										<input class="form-border" id="residenceBack" type="text" readonly @click="openCityShow('residenceBack')" name="residenceBack"  placeholder="请填写返回起始地点" v-model="residenceBack"  /> <br/>
									</div>
					
					<label for="vehicle" required>6. 返程交通工具</label><span class="required" style="color:red">*</span><br/>
					<div class="form-border tizheng clearfix" style='border: 1px solid #c6c8c9;'>
						<div>
							<el-checkbox  v-model="Backvehicle" label="火车"></el-checkbox>
						</div>
						<div>
							<el-checkbox  v-model="Backvehicle" label="飞机"></el-checkbox>
						</div>
						<div>
							<el-checkbox  v-model="Backvehicle" label="自驾"></el-checkbox>
						</div>
					</div>
					<!-- <div class="form-border form-twoBor" style='border: 1px solid #c6c8c9;'>
						<div  >
							<el-radio v-model="Backvehicle" label="火车"></el-radio>
						</div>
						<div style="border-top: 1px solid #c6c8c9; " >
							<el-radio v-model="Backvehicle" label="飞机"></el-radio>
						</div>
						<div style="border-top: 1px solid #c6c8c9; " >
							<el-radio v-model="Backvehicle" label="自驾"></el-radio>
						</div>

					</div> -->
					<div class="yy-c trainNumber">
						<label for="vehicle">7. 车次号/航班号/自驾车牌照</label>
						<input class="form-border" id="trainNumberBack" maxlength="32" type="text" name="trainNumberBack"   placeholder="请输入车次或航班号"  v-model="trainNumberBack"  /> <br/>
					</div>
					<div class="query-time" style="position: relative;">
					
						<label for="name" class="littleTile">8. 返程日期</label><span class="required" style="color:red">*</span><br/>
						<div style="margin-top: 10px;margin-bottom: 20px; width:100%; height: 32px; line-height:32px; border: 1px solid #cccccc; text-align: center; " @click="returnDateShow=true" >
							<span class="select_show">{{returnDate}}</span>
						</div>
						<span @click="returnDate=''" v-if="returnDate" style="position: absolute;right: 0;top: 31px;margin-right: 10px;padding: 0 10px;font-size: 18px;line-height: 1.7;">x</span>
						<datetime style="display:none;" v-model="returnDate" @on-change="changeTime" :show.sync="returnDateShow"></datetime>
					</div>
					<!-- <div class="query-time" v-show="showPostDate">
						<label for="name">返回日期</label><br/>
						<div style="margin-top: 10px;margin-bottom: 20px; width:100%; height: 32px; line-height:32px; border: 1px solid #cccccc; text-align: center; " @click="postDateShow=true" >
							<span class="select_show">{{postDate}}</span>
						</div>
						<span @click="postDate=''" v-if="postDate" style="position: absolute;right: 0;top: 31px;margin-right: 10px;padding: 0 10px;font-size: 18px;line-height: 1.7;">x</span>
						<datetime style="display:none;" v-model="postDate" @on-change="changeTime" :show.sync="postDateShow"></datetime>
					</div> -->
					<label for="gender" required>9. 随行家属</label><br/>
					<div class="form-border tizheng clearfix" style='border: 1px solid #c6c8c9;'>
						<div>
							<el-checkbox  v-model="backTogether" label="父母"></el-checkbox>
						</div>
						<div>
							<el-checkbox  v-model="backTogether" label="子女"></el-checkbox>
						</div>
						<div>
							<el-checkbox  v-model="backTogether" label="配偶"></el-checkbox>
						</div>
						<div>
							<el-checkbox  v-model="backTogether" label="亲属"></el-checkbox>
						</div>
					</div>

					
					<label for="gender" required>10 家属身体状况</label><br/>
					<div class="form-border form-twoBor" style='border: 1px solid #c6c8c9;'>
						<div >
							<el-radio v-model="familySymptom" label="0">正常</el-radio>
						</div>
						<div style="border-top: 1px solid #c6c8c9; " >
							<el-radio v-model="familySymptom" label="1">异常</el-radio>
						</div>
					</div>
					
					<label for="gender" required>11. 是否向所在社区居委会登记报到</label><span class="required" style="color:red">*</span><br/>
					<div class="form-border form-twoBor" style='border: 1px solid #c6c8c9;'>
						<div  >
							<el-radio v-model="reportCommittee" label="1">是</el-radio>
						</div>
						<div style="border-top: 1px solid #c6c8c9;" >
							<el-radio v-model="reportCommittee" label="0">否</el-radio>
						</div>
					</div>
					
					<label for="gender" required>12. 外地返回是否做自我居家隔离14天</label><span class="required" style="color:red">*</span><br/>
					<div class="form-border form-twoBor" style='border: 1px solid #c6c8c9;'>
						<div  >
							<el-radio v-model="fourteenDayIsolation" label="1">居家隔离完成</el-radio>
						</div>
						<div style="border-top: 1px solid #c6c8c9;" >
							<el-radio v-model="fourteenDayIsolation" label="2">隔离中</el-radio>
						</div>
						<div style="border-top: 1px solid #c6c8c9;" >
							<el-radio v-model="fourteenDayIsolation" label="3">未隔离</el-radio>
						</div>
					</div>
					<div class="query-time">
						<label for="planBackDate">13. 预计解除自我隔离时间</label><br/>
						<div style="margin-top: 10px;margin-bottom: 20px; width:100%; height: 32px; line-height:32px; border: 1px solid #cccccc; text-align: center; " @click="relieveDateShow=true">
							<span class="select_show">{{relieveDate}}</span>
						</div>
						<span @click="relieveDate=''" v-if="relieveDate" style="position: absolute;right: 0;top: 31px;margin-right: 10px;padding: 0 10px;font-size: 18px;line-height: 1.7;">x</span>
						<datetime style="display:none;"  v-model="relieveDate" @on-change="changeTime" :show.sync="relieveDateShow"></datetime>
					</div>
					
					<label for="leave" required>14. 近期是否离开固定驻地</label><span class="required" style="color:red">*</span><br/>
					<div class="form-border form-twoBor" style='border: 1px solid #c6c8c9;'>
						<div>
							<el-radio v-model="leaveHabitation" @change="leaveDate='';toCity='';back='';" label="0">否</el-radio>
						</div>
						<div style="border-top: 1px solid #c6c8c9; " >
							<el-radio v-model="leaveHabitation" label="1">是</el-radio>
						</div>
					</div>

					<div v-show="leaveHabitationShow">
						<div class="query-time" v-if="leaveHabitation==1">
							<label for="name">15. 离开固定驻地时间</label><span class="required" style="color:red">*</span><br/>
							<div style="margin-top: 10px;margin-bottom: 20px; width:100%; height: 32px; line-height:32px; border: 1px solid #cccccc; text-align: center; " @click="leaveDateShow=true">
								<span class="select_show">{{leaveDate}}</span>
							</div>
							<span @click="leaveDate=''" v-if="leaveDate" style="position: absolute;right: 0;top: 31px;margin-right: 10px;padding: 0 10px;font-size: 18px;line-height: 1.7;">x</span>
							<datetime style="display:none;" :end-date="endDate" v-model="leaveDate" @on-change="changeTime" :show.sync="leaveDateShow"></datetime>
						</div>
						<div class="toCity" v-if="leaveHabitation==1">
							<label for="toCity">16. 所赴城市</label><span class="required" style="color:red">*</span><br/>
							<input class="form-border" id="toCity" @click="openCityShow('toCity')" readonly type="text" name="toCity" maxlength="20" placeholder="所赴城市" required="required" v-model="toCity"  /> <br/>
						</div>
						<div v-if="leaveHabitation==1">
							
							<label for="back" required>17. 是否已返回</label><span class="required" style="color:red">*</span><br/>
							<div class="form-border form-twoBor" style='border: 1px solid #c6c8c9;'>
								<div  >
									<el-radio v-model="back" label="0">否</el-radio>
								</div>
								<div style="border-top: 1px solid #c6c8c9; " >
									<el-radio v-model="back" label="1">是</el-radio>
								</div>
							</div>
						</div>

						<div class="query-time">
							<label for="backDate">17. 返回时间</label><span class="required" style="color:red">*</span><br/>
							<div style="margin-top: 10px;margin-bottom: 20px; width:100%; height: 32px; line-height:32px; border: 1px solid #cccccc; text-align: center; " @click="backDateshow=true">
								<span class="select_show">{{backDate}}</span>
							</div>
							<span @click="backDate=''" v-if="backDate" style="position: absolute;right: 0;top: 31px;margin-right: 10px;padding: 0 10px;font-size: 18px;line-height: 1.7;">x</span>
							<datetime style="display:none;" v-model="backDate" @on-change="changeTime" :show.sync="backDateshow"></datetime>
						</div>

						
						<label for="touchHubei" required>18. 离开期间是否与湖北地区的人员接触</label><span class="required" style="color:red">*</span><br/>
						<div class="form-border form-twoBor" style='border: 1px solid #c6c8c9;'>
							<div>
								<el-radio v-model="touchHubei" label="0">否</el-radio>
							</div>
							<div style="border-top: 1px solid #c6c8c9; " >
								<el-radio v-model="touchHubei" label="1">是</el-radio>
							</div>
						</div>

						
						<label for="passHubei" required>19. 1月1日以后是否去过湖北</label><span class="required" style="color:red">*</span><br/>
						<div class="form-border form-twoBor" style='border: 1px solid #c6c8c9;'>
							<div >
								<el-radio v-model="beenHubei" label="0">否</el-radio>
							</div>
							<div style="border-top: 1px solid #c6c8c9;" >
								<el-radio v-model="beenHubei" @change="beenHubeiFlag" label="1">是</el-radio>
							</div>
						</div>
						<div class="query-time" v-if="beenHubei==1">
							<label for="planBackDate">20. 去湖北时间</label><br/>
							<div style="margin-top: 10px;margin-bottom: 20px; width:100%; height: 32px; line-height:32px; border: 1px solid #cccccc; text-align: center; " @click="beenHubeiDateShow=true">
								<span class="select_show">{{beenHubeiDate}}</span>
							</div>
							<span @click="beenHubeiDate=''" v-if="beenHubeiDate" style="position: absolute;right: 0;top: 31px;margin-right: 10px;padding: 0 10px;font-size: 18px;line-height: 1.7;">x</span>
							<datetime style="display:none;" :end-date="endDate" v-model="beenHubeiDate" @on-change="changeTime" :show.sync="beenHubeiDateShow"></datetime>
						</div>
						<div class="query-time" v-if="beenHubei==1">
							<label for="planBackDate">21. 离开湖北时间</label><br/>
							<div style="margin-top: 10px;margin-bottom: 20px; width:100%; height: 32px; line-height:32px; border: 1px solid #cccccc; text-align: center; " @click="leaveHubeiDateShow=true">
								<span class="select_show">{{leaveHubeiDate}}</span>
							</div>
							<span @click="leaveHubeiDate=''" v-if="leaveHubeiDate" style="position: absolute;right: 0;top: 31px;margin-right: 10px;padding: 0 10px;font-size: 18px;line-height: 1.7;">x</span>
							<datetime style="display:none;" :end-date="endDate" v-model="leaveHubeiDate" @on-change="changeTime" :show.sync="leaveHubeiDateShow"></datetime>
						</div>
						
						<label for="passHubei" required><span>{{beenHubei==1?'22':'20'}}</span>. 是否经停湖北</label><span class="required" style="color:red">*</span><br/>
						<div class="form-border form-twoBor" style='border: 1px solid #c6c8c9;'>
							<div >
								<el-radio v-model="passHubei" label="0">否</el-radio>
							</div>
							<div style="border-top: 1px solid #c6c8c9;" >
								<el-radio v-model="passHubei" label="1">是</el-radio>
							</div>
						</div>
						<!-- <div class="query-time">
							<label for="planBackDate">计划返回时间</label><br/>
							<div style="margin-top: 10px;margin-bottom: 20px; width:100%; height: 32px; line-height:32px; border: 1px solid #cccccc; text-align: center; " @click="planBackDateShow=true">
								<span class="select_show">{{planBackDate}}</span>
							</div>
							<span @click="planBackDate=''" v-if="planBackDate" style="position: absolute;right: 0;top: 31px;margin-right: 10px;padding: 0 10px;font-size: 18px;line-height: 1.7;">x</span>

							<datetime style="display:none;" v-model="planBackDate" @on-change="changeTime" :show.sync="planBackDateShow"></datetime>
						</div> -->
						
						
						<label for="gender" required><span>{{beenHubei==1?'23':'21'}}</span>. 14日内是否接触过武汉来人</label><span class="required" style="color:red">*</span><br/>
						<div class="form-border form-twoBor" style='border: 1px solid #c6c8c9;'>
							<div  >
								<el-radio v-model="fourteenDayTouchWuhan" label="0">否</el-radio>
							</div>
							<div style="border-top: 1px solid #c6c8c9; " >
								<el-radio v-model="fourteenDayTouchWuhan" label="1">是</el-radio>
							</div>
						</div>
						
						<label for="gender" required><span>{{beenHubei==1?'24':'22'}}</span>. 14日内是否接触过湖北来人</label><span class="required" style="color:red">*</span><br/>
						<div class="form-border form-twoBor" style='border: 1px solid #c6c8c9;'>
							<div  >
								<el-radio v-model="fourteenDayTouchHubei" label="0">否</el-radio>
							</div>
							<div style="border-top: 1px solid #c6c8c9; " >
								<el-radio v-model="fourteenDayTouchHubei" label="1">是</el-radio>
							</div>
						</div>
					</div>
				</div>
                
				
			</div>

		</div>
		<div v-transfer-dom>
			<popup v-model="showSelectPopup" @on-hide="changeState('hide')" @on-show="changeState('show')"  height="50%">
				<menuLinkage :queryObj="casList" @setCityObj="setCityObj" ref="menuLinkage" />
			</popup>
		</div>
<!-- 
		<div v-transfer-dom>
			<popup v-model="showSelectCityPopup" @on-hide="changeState('hide')" @on-show="changeState('show')" height="50%">
				<menuLinkage :queryObj="casListCity" @setCityObj="setCityObjTwo" ref="menuLinkageTwo" />
			</popup>
		</div> -->
		<div v-transfer-dom>
			<popup v-model="showSelectToCityPopup" @on-hide="changeState('hide')" @on-show="changeState('show')" height="50%">
				<menuLinkage :queryObj="casListCity" @setCityObj="setToCityObjTwo" ref="menuLinkageOne" />
			</popup>
		</div>
		<!-- <div v-transfer-dom>
			<popup v-model="showSelectBackCityPopup" @on-hide="changeState('hide')" @on-show="changeState('show')" height="50%">
				<menuLinkage :queryObj="casListCity" @setCityObj="setBackCityObjTwo" ref="menuLinkageTwo" />
			</popup>
		</div> -->

	</div>
</template>
<script>
import { requestEnterpriseData ,queryCityData,queryCityDataForTwo,} from '@/assets/js/service'
import fromConfig from '../../../static/formConfig'
import { Confirm , Datetime,PopupPicker,Popup,TransferDom} from 'vux'
import menuLinkage from '../commons/menuLinkage.vue'
import { forbiddenBar } from '@/assets/js/common'

export default {
	directives: {
		TransferDom
	},
    components: {
        Confirm,
        Datetime,
        PopupPicker,
        Popup,
        menuLinkage
    },
    data () {
        return {
						giveBack:'0',
						Backvehicle:[],
						trainNumberBack:'',
            // 以上新增
						casList:[],
						casModel:[],
						casListCity:[],
						showSelectPopup:false,//是否显示级联组件
						showBackdiv:false,
						showSelectCityPopup:false,//显示城市组件
						showSelectToCityPopup:false,//显示去的城市组件

						showSelectBackCityPopup:false,//显示去的城市组件
						flagCity:"",//标识当前选中城市赋值
						backDateshow:false,
						leaveDateShow:false,
						postDateShow:false,
						planBackDateShow:false,
						relieveDateShow:false,
						beenHubeiDateShow:false,
						leaveHubeiDateShow:false,
						showPostDate:true,
						endDate:"",//限定最大日期
						leaveHabitationShow:false,
						remnant:0,
						// 表单字段

						returnDate:"",//返程时间
						returnDateShow:false,//

						vehicle:[],//离开与返回的交通工具
						beenHubei:"0",//1月1日以后是否去过湖北

						address:'',//固定居住地址（城市、区县、街道、社区、小区、楼栋、单元、楼层、房间号）
						residence:'',//
						community:'',//您所在的小区
						communityCode:'',//小区编码
						building:'',//楼号
						unit:'',//单元
						roomNumber:'',//房间号

						currentProvince:'',//当前所在省
						currentCity:'',//市（当前所在地）
						currentCounty:'',//区/县
						currentCountry:'',//街道/乡/镇
						currentVillage:'',//社区/村
						//返回的省市县
						residenceBack:'',//返回地
						currentProvinceBack:'',//返回省
						currentCityBack:'',//返回市（当前所在地）
						currentCountyBack:'',//返回区/县
						currentCountryBack:'',//返回街道/乡/镇
						currentVillageBack:'',//返回社区/村
						currentProvinceCodeBack:'',//当前所在省 code
						currentCityCodeBack:'',//当前所在市 code
						currentCountyCodeBack:'',//当前所在区/县 code
						currentCountryCodeBack:'',//街道/乡/镇（当前所在地）code
						currentVillageCodeBack:'',////社区/村（当前所在地）code
						communityCodeBack:'',//小区code
						//新增
						currentProvinceCode:'',//当前所在省 code
						currentCityCode:'',//当前所在市 code
						currentCountyCode:'',//当前所在区/县 code
						currentCountryCode:'',//街道/乡/镇（当前所在地）code
						currentVillageCode:'',////社区/村（当前所在地）code
						communityCode:'',//小区code

						postDate:'',//预计返岗日期
						leaveHabitation:'0',//近期是否离开固定驻地（1是、0否）
						leaveDate:'',//离开固定驻地时间
						toCity:'',//所赴城市
						back:'0',//是否已返回（1是、0否）
						currentCityName:'',//目前所在城市
						backDate:'',//返回时间
						passHubei:'0',//是否经停湖北（1是,0否）
						planBackDate:'',//计划返回时间
						touchHubei:'0',//离开期间是否与湖北地区的人员接触
						fourteenDayTouchWuhan:'0',//14日内是否接触过武汉来人（1是,0否）
						fourteenDayTouchHubei:'0',//14日内是否接触过湖北来人（1是,0否）
						fever:'0',//是否发热（>=37.3度）（1是,0否）
						symptom:[],//其它症状
						backTogether:[],//一起返回的家属（父母、爱人、孩子、孙子女、亲属）
						familySymptom:'0',//家属身体状况（0正常，1异常）
						reportCommittee:'1',//是否向所在社区居委会登记报到（1是,0否）
						fourteenDayIsolation:'1',//外地返回是否做自我居家隔离14天（1居家隔离完成、2隔离中、3未隔离）
						remark:'',//其他需要报告的情况

						personnelType:"3",//人群类型（0:确诊，1:疑似，2:密接）
						relieveDate:"",//解决隔离时间
						trainNumber:"",//车次或航班号
						beenHubeiDate:"",//去湖北时间
						leaveHubeiDate:"",//离开湖北时间
						peopleWuhan:"",//接触武汉人信息
						peopleHubei:"",//接触湖北人信息
            countdownFlag:true,
        }
    },
    created () {
			
				this.endDate=this.$formatTimeStr(new Date(),1);

				this.initcascade();

				let arr = JSON.parse(localStorage.getItem('enterpriseHomeData'))
				if(arr) {
					let personInfo = JSON.parse(arr[0])
					this.giveBack = personInfo.otherPlaceBack;
					this.residence = personInfo.goStartingPoint;
					this.vehicle = personInfo.goVehicle.split("-");
					this.trainNumber = personInfo.goTrainNumber;
					this.residenceBack = personInfo.backStartingPoint;
					this.Backvehicle = personInfo.backVehicle.split("-"); //返程交通工具 飞机、火车、大巴、自驾'
					this.trainNumberBack = personInfo.backTrainNumber;
					this.returnDate = personInfo.returnDate;
					this.leaveHabitation = personInfo.leaveHabitation;
					this.leaveDate = personInfo.leaveDate;
					this.toCity = personInfo.toCity;
					this.back = personInfo.back;
					this.backDate = personInfo.backDate;
					this.touchHubei = personInfo.touchHubei;
					this.beenHubei = personInfo.beenHubei;
					this.beenHubeiDate = personInfo.beenHubeiDate; //去湖北时间
					this.leaveHubeiDate = personInfo.leaveHubeiDate; //离开湖北时间
					this.passHubei = personInfo.passHubei; //是否经停湖北
					this.fourteenDayTouchWuhan =
						personInfo.fourteenDayTouchWuhan; //14日内是否接触过武汉来人（1是,0否）
					this.fourteenDayTouchHubei = personInfo.fourteenDayTouchHubei; //14日内是否接触过湖北来人（1是,0否）
					this.backTogether = personInfo.backTogether.split(","); //一起返回的家属
					this.familySymptom = personInfo.familySymptom; //家属身体状况（0正常，1异常）
					this.reportCommittee = personInfo.reportCommittee;
					this.fourteenDayIsolation =
						personInfo.fourteenDayIsolation; //外地返回是否做自我居家隔离14天
					this.relieveDate = personInfo.relieveDate;
				}
    },
    mounted: function () {
			
    },
    watch:{
		giveBack(){
			if(this.giveBack=="0"){
				this.showBackdiv=false;
			}else{
				this.showBackdiv=true;
			}
		},
		remark(){
			this.remnant=this.remark.length;
		},
		// enterpriseName(){
		// 	let namelength= this.enterpriseName.length;
		// 	if(namelength>20){
		// 		window.vm.$vux.toast.text('所属单位不能大于20', 'center')
		// 		this.enterpriseName=this.enterpriseName.substr(0,20)
		// 	}
		// },
		residenceBack(){
		// 	 console.log(this.currentProvince)
        //   console.log(this.currentProvince.substr(0,2))
        //    if( this.currentProvinceBack.substr(0,2)=="香港" || this.currentProvinceBack.substr(0,2)=="澳门"){
        //      this.residenceBack = this.currentProvinceBack ;
        //      this.currentCityBack = '';
        //      this.currentCountyBack = '';
        //      this.currentCountryBack = '';
        //      this.currentVillageBack = '';
        //    } else if(this.currentCountryBack == ''){
        //     //  console.log(1)
        //      this.residenceBack = this.currentProvinceBack +'/'+ this.currentCityBack +'/'+ this.currentCountyBack;
        //    } else {
        //       // console.log(2)
        //     this.residenceBack = this.currentProvinceBack +'/'+ this.currentCityBack +'/'+ this.currentCountyBack +'/'+ this.currentCountryBack +'/'+ this.currentVillageBack;
        //   }

		},
		leaveHabitation(){
			if(this.leaveHabitation=='1'){
				this.leaveHabitationShow=true;
			}else{
				this.leaveHabitationShow=false;
			}
		},
		dutyStatus(){
			if(this.dutyStatus&&parseInt(this.dutyStatus)>2){
				this.showPostDate=true;
			}else{
				this.showPostDate=false;
				this.postDate='';
			}
		},
		beenHubeiDate(){
			if(this.beenHubeiDate&&this.leaveHubeiDate&&this.beenHubeiDate>this.leaveHubeiDate){
				window.vm.$vux.toast.text('离开湖北时间不能早于去湖北时间', 'center')
				this.beenHubeiDate="";
			}
		},
		leaveHubeiDate(){
			if(this.beenHubeiDate&&this.leaveHubeiDate&&this.beenHubeiDate>this.leaveHubeiDate){
				window.vm.$vux.toast.text('离开湖北时间不能早于去湖北时间', 'center')
				this.leaveHubeiDate="";
			}
		},
    },
    methods: {
		changeState(statusFlag){
			console.log(statusFlag)
		},
		beenHubeiFlag(){
			if(this.beenHubei==1){
				this.leaveHubeiDate='';
				this.beenHubeiDate='';
			}
    },
    isReturnOrNot(){

		},
    submitClick(){
		},
		changeTime(){

		},
		openCityShow(flag){
			this.flagCity=flag;
			this.showSelectToCityPopup=true;

		},
		openToCityShow() {
			this.showSelectToCityPopup=true;
		},
		initcascade(){
					let _this=this;
					queryCityData({"parentCode":"000000"},function(res){
							// console.log("resaaaaaaaaaaaaaaaaaaaa==>",res)
							_this.casList=[];
							if(typeof(res.data)!="undefined"&&res.data.length>0){
									_this.casList=res.data;
									_this.$refs.menuLinkage.initData(_this.casList,1);
									// 去掉默认的北京市固定地址
									// _this.$refs.menuLinkage.setDefault(['北京市'])
							}
		})
			//初始化行政区划二级
		queryCityDataForTwo({},function(res){
				console.log("res==>",res)
				_this.casListCity=[];
				if(typeof(res.data)!="undefined"&&res.data.length>0){
						_this.casListCity=res.data;
						//_this.$refs.menuLinkageTwo.initData(_this.casListCity,0);
						_this.$refs.menuLinkageOne.initData(_this.casListCity,0);
				}
		})
		},
		setCityObj(_list){
			if(typeof(_list[0])!='undefined'){
					this.currentProvince=_list[0].name;
					this.currentProvinceCode=_list[0].code;
					
			}
			if(typeof(_list[1])!='undefined'){
					this.currentCity=_list[1].name;
					this.currentCityCode=_list[1].code;
			}
			if(typeof(_list[2])!='undefined'){
					this.currentCounty=_list[2].name;
					this.currentCountyCode=_list[2].code;
					
			}
			if(typeof(_list[3])!='undefined'){
					this.currentCountry=_list[3].name;
					this.currentCountryCode=_list[3].code;
					
			}else{
					this.currentCountry="";
			}
			if(typeof(_list[4]) !='undefined'){
				this.currentVillage = _list[4].name;
				this.currentVillageCode = _list[4].code;
			} else {
				this.currentVillage = '';
			}
			this.showSelectPopup=false;
		},
		setToCityObjTwo(_list){
			//residence residenceBack
			if(this.flagCity=='residence'){
				if(typeof(_list[0])!='undefined'){
					this.residence=_list[0].name;
				}
				if(typeof(_list[1])!='undefined'){
					this.residence=this.residence+"/"+_list[1].name;
				}
			}else if(this.flagCity=='residenceBack'){
				if(typeof(_list[0])!='undefined'){
					this.residenceBack=_list[0].name;
				}
				if(typeof(_list[1])!='undefined'){
					this.residenceBack=this.residenceBack+"/"+_list[1].name;
				}
			}else{
				if(typeof(_list[0])!='undefined'){
					this.toCity=_list[0].name;
				}
				if(typeof(_list[1])!='undefined'){
					this.toCity=this.toCity+"/"+_list[1].name;
				}
			}
			
			this.showSelectToCityPopup=false;
		},
		// setBackCityObjTwo(_list){

		// 	if(typeof(_list[0])!='undefined'){
		// 			this.currentProvinceBack=_list[0].name;
		// 			this.currentProvinceCodeBack=_list[0].code;
		// 			this.residenceBack=_list[0].name;
		// 	}
		// 	if(typeof(_list[1])!='undefined'){
		// 			this.currentCityBack=_list[1].name;
		// 			this.currentCityCodeBack=_list[1].code;
		// 			this.residenceBacak=this.residenceBack+"/"+_list[1].name;
		// 	}
		// 	if(typeof(_list[2])!='undefined'){
		// 			this.currentCountyBack=_list[2].name;
		// 			this.currentCountyCodeBack=_list[2].code;
		// 			this.residenceBack=this.residenceBack+"/"+_list[2].name;
		// 	}
		// 	if(typeof(_list[3])!='undefined'){
		// 			this.currentCountryBack=_list[3].name;
		// 			this.currentCountryCodeBack=_list[3].code;
		// 			this.residenceBack=this.residenceBack+"/"+_list[3].name;
		// 	}else{
		// 			this.currentCountryBack="";
		// 	}
		// 	if(typeof(_list[4]) !='undefined'){
		// 		this.currentVillageBack = _list[4].name;
		// 		this.currentVillageCodeBack = _list[4].code;
		// 		this.residenceBack=this.residenceBack+"/"+_list[4].name;
		// 	} else {
		// 		this.currentVillageBack = '';
		// 	}
		// 	this.showSelectPopup=false;
		// },
		verifyBar(e) {
			console.log('wanchegnle 输入')
			let reg = /[@#\$%\^&\*]+/g
			if(reg.test(e.target.value)){
				window.vm.$vux.toast.text('含有非法字符，请重新输入', 'center')
			}
			// e.target.value = forbiddenBar(e.target.value);
		},
    }
}
</script>
<style lang="less" scoped>

.main{
    overflow: hidden;
    // background: url("../../assets/images/home/bj.png") 0 0;
    background-size: 100% 100%;
    .form-container{
        background: #f8fafb;
        background-size: 100% 100%;
        width: calc(100% -16px);
        border-radius: 8px;
        border: solid 1px #e5e5e5;
        // margin: 0 3%;
        margin-left:8px;
        margin-right:8px;
        // margin-bottom: 10px;
        padding-bottom: 25px;
        .name {
          padding-top: 15px;
        }
        .form-main{
            width: 100%;
            // margin-top: 130px;
            margin-bottom: 30px;
            padding: 0 20px;
			color: #333333;
			position: relative;
			padding-top: 40px;
			label{
				font-size: 15px;
				font-weight: bold;
			}
			.one_title{
				height: 30px;
				line-height: 21px;
				display: block;
				position: absolute;
				font-size: 17px;
				font-weight: 700;
				top: 0;
				left: 10px;
				border-bottom-left-radius: 12px;
				border-bottom-right-radius: 12px;
				padding: 4px 0;
				background: rgba(119,136,153,.2);
			}
			 .littleTile{
				font-size: 15px;
				font-weight: bold;
			}
            .warn-content{
                margin-top: 10px;
                margin-bottom: 18px;
                line-height: 30px;
                font-size: 15px;
            }
            h2{
                text-align: center;
                color: #fff;
                width: calc(100% + 40px);
                margin-left: -20px;
                border-bottom: 1px solid rgba(255, 255, 255, 0.24);
                height: 60px;
                line-height: 60px;
                font-size: 24px;
            }
            h4{
                margin-top: 15px;
            }
            .form-border{
                background-color: rgba(255, 255, 255, 0.9);
                color: #333333;
                padding:5px;
                margin: 9px 0;
                width: 100%;
                margin-bottom: 20px;
                border-radius: 3px;
            }
            .tizheng{
                div{
                    width: 33.3333%;
                    float: left;
                    padding: 10px 5px;
                    font-size: 15px;
                    input{
                        vertical-align: middle;
                        width: 15px;
                        height: 15px;
                    }
                }
            }
            .form-twoBor{
                padding: 5px 0;
                div{
                    width: 100%;
                    padding: 5px 10px;
                    input{
                        vertical-align: middle;
                        width: 20px;
                        height: 20px;
                    }
                    label{
                        font-size: 15px;
                    }
                }

            }
            
        }
        .form-submit{
            width: 90%;
            margin-left: 5%;
            height: 50px;
            background: #228ed9;
            border-radius: 8px;
            color: white;
            font-size: 15px;
            border: none;
            outline: none;
        }
    }
label{
//   color: #000;
}

input{
    border: 1px solid #cccccc;
}
.el-input__inner{
  color: #fdfdfd;
}
.el-radio{
  margin: 5px;
  left: -5px;
  .el-radio__label{
    color: #000;
  }
  .el-radio__input.is-checked+.el-radio__label{
    color: #000 !important;
  }
}
}
</style>